package com.kelvin.paopao.widgets.dialog;

import android.content.Context;

import com.airsaid.pickerviewlibrary.OptionsPickerView;

import java.util.ArrayList;
import java.util.List;

/**
 * Created by MCK on 2017/5/15.
 */

public class OptionSelector {
    public static ArrayList<String> tallList = new ArrayList<>();
    public static ArrayList<String> ageList = new ArrayList<>();
    public static ArrayList<String> weightList = new ArrayList<>();
    public static ArrayList<String> accountList = new ArrayList<>();
    public static ArrayList<String> starList = new ArrayList<>();
    public static ArrayList<String> relationShip = new ArrayList<>();
    public static ArrayList<String> sendGoodTime = new ArrayList<>();

    public static ArrayList<String> locations = new ArrayList<>();
    public static ArrayList<String> wechatLogin = new ArrayList<>();

    static {
        wechatLogin.add("绑定已有账户");
        wechatLogin.add("新建账户");

        tallList.add("小于1米5");
        tallList.add("1米5到1米6");
        tallList.add("1米6到1米7");
        tallList.add("1米7到1米8");
        tallList.add("大于1米8");

        ageList.add("小于20岁");
        ageList.add("20到30岁");
        ageList.add("30到40岁");
        ageList.add("大于40岁");

        weightList.add("小于40kg");
        weightList.add("40到50kg");
        weightList.add("50到60kg");
        weightList.add("60到70kg");
        weightList.add("70到80kg");
        weightList.add("大于80kg");

        accountList.add("小于3000元");
        accountList.add("3000到5000元");
        accountList.add("5000到8000元");
        accountList.add("8000到10000元");
        accountList.add("大于10000元");

        starList.add("白羊座");
        starList.add("金牛座");
        starList.add("双子座");
        starList.add("巨蟹座");
        starList.add("狮子座");
        starList.add("处女座");
        starList.add("天枰座");
        starList.add("天蝎座");
        starList.add("射手座");
        starList.add("摩羯座");
        starList.add("水瓶座");
        starList.add("双鱼座");

        relationShip.add("单身");
        relationShip.add("恋爱中");
        relationShip.add("已婚");
        relationShip.add("离异");

        sendGoodTime.add("星期一到五9：00到18：00");
        sendGoodTime.add("星期一到五18：00到22：00");
        sendGoodTime.add("星期六，日");
        sendGoodTime.add("任意时间");

        locations.add("选择地点");
        locations.add("大概地点");
    }

    /**
     * 显示高度选择器
     */
    public static OptionsPickerView showTallSelector(Context context) {
        OptionsPickerView mOptionsPickerView = new OptionsPickerView<>(context);

        // 设置数据
        mOptionsPickerView.setPicker(tallList);
        // 设置选项单位
//        mOptionsPickerView.setLabels("性");
        mOptionsPickerView.show();
        return mOptionsPickerView;
    }

    /**
     * 显示微信登陆选择器
     */
    public static OptionsPickerView showWechatSeletor(Context context) {
        OptionsPickerView mOptionsPickerView = new OptionsPickerView<>(context);

        mOptionsPickerView.setPicker(wechatLogin);
        mOptionsPickerView.show();
        return mOptionsPickerView;
    }

    /**
     * 显示送货时间选择器
     */
    public static OptionsPickerView showSendGoodTimeSeletor(Context context) {
        OptionsPickerView mOptionsPickerView = new OptionsPickerView<>(context);

        // 设置数据
        mOptionsPickerView.setPicker(sendGoodTime);
        // 设置选项单位
//        mOptionsPickerView.setLabels("性");
        mOptionsPickerView.show();
        return mOptionsPickerView;
    }

    /**
     * 显示年齡选择器
     */
    public static OptionsPickerView showAgeSelector(Context context) {
        OptionsPickerView mOptionsPickerView = new OptionsPickerView<>(context);

        // 设置数据
        mOptionsPickerView.setPicker(ageList);
        // 设置选项单位
//        mOptionsPickerView.setLabels("性");
        mOptionsPickerView.show();
        return mOptionsPickerView;
    }


    /**
     * 显示体重选择器
     */
    public static OptionsPickerView showWeightSelector(Context context) {
        OptionsPickerView mOptionsPickerView = new OptionsPickerView<>(context);

        // 设置数据
        mOptionsPickerView.setPicker(weightList);
        // 设置选项单位
        mOptionsPickerView.show();
        return mOptionsPickerView;
    }


    /**
     * 显示收入选择器
     */
    public static OptionsPickerView showAccountSelector(Context context) {
        OptionsPickerView mOptionsPickerView = new OptionsPickerView<>(context);

        // 设置数据
        mOptionsPickerView.setPicker(accountList);
        // 设置选项单位
        mOptionsPickerView.show();
        return mOptionsPickerView;
    }


    /**
     * 显示收入选择器
     */
    public static OptionsPickerView showStarSelector(Context context) {
        OptionsPickerView mOptionsPickerView = new OptionsPickerView<>(context);
        // 设置数据
        mOptionsPickerView.setPicker(starList);
        // 设置选项单位
        mOptionsPickerView.show();
        return mOptionsPickerView;
    }


    /**
     * 显示收入选择器
     */
    public static OptionsPickerView showRelationShipSelector(Context context) {
        OptionsPickerView mOptionsPickerView = new OptionsPickerView<>(context);
        // 设置数据
        mOptionsPickerView.setPicker(relationShip);
        // 设置选项单位
        mOptionsPickerView.show();
        return mOptionsPickerView;
    }

    /**
     * 显示地点选择器
     */
    public static OptionsPickerView showLocationSelector(Context context) {
        OptionsPickerView mOptionsPickerView = new OptionsPickerView<>(context);
        // 设置数据
        mOptionsPickerView.setPicker(locations);
        // 设置选项单位
        mOptionsPickerView.show();
        return mOptionsPickerView;
    }
}
